/**
 * 
 */
package cloud.simple.hello;

import org.springframework.beans.factory.annotation.Value;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

/**
 * @author zhaodarong
 *
 */
@SpringBootApplication
@Controller
public class SampleController {
	
	@Value("${my.message}")
	String greeting;
	
	@RequestMapping("/")
	@ResponseBody
	String home() {
		return "hello world! " + greeting;
	}
	
	public static void main(String[] args) {
		SpringApplication.run(SampleController.class, args);
	}

}
